//
//  UserDao.h
//  eyr
//
//  Created by Tor Gjøsæter on 4/25/12.
//  Copyright (c) 2012 University of Bergen. All rights reserved.
//

#import <Foundation/Foundation.h>

@interface UserDao : NSObject

@property (nonatomic, strong) UIManagedDocument *userDataBase;

- (id) initWithDataBase:(NSString *)fileUrl;
- (void) addUserToDocument:(NSString *) name;
- (void) addUser:(NSString *) name;

//- (void) loadUserDataIntoDocument:(UIManagedDocument *) document;


- (void) addTestBruker;
- (void) loadTestBrukerDataIntoDocument:(UIManagedDocument *) document;

- (void) setUserDataBase:(UIManagedDocument *) userDataBase;

+ (UserDao *) sharedSingleton;
- (void) deleteUserObject:(NSString *) name;
- (void) commitUserDelete;

@end
